<template>
  <view class="service">
    <custom-nav title="" theme="red"></custom-nav>

    <content-card></content-card>
    <bottom-card v-if="!isMember"></bottom-card>

    <!-- 客服悬浮 -->
    <custom-serve></custom-serve>
  </view>
</template>

<script setup>
import ContentCard from "./components/content-card.vue";
import BottomCard from "./components/bottom-card.vue";
import { getItem } from "@/utils/storage";
import useStore from "@/store";
const { app, common } = useStore();

const isMember = ref(false);

onShow(() => {
  app
    .getUserInfo()
    .then((res) => {
      const { title } = res.member || {};
      isMember.value = title && title == "至尊会员";
    })
    .catch((err) => {
      isMember.value = false;
    });
});
</script>

<style lang=scss scoped>
.service {
  width: 100vw;
  height: 100vh;
  overflow-y: scroll;
  @include borderBox;
  position: relative;
  padding-bottom: 100rpx;
}
</style>